package com.bwie.controller;

import com.bwie.service.TbDictService;
import com.bwie.utils.R;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @Author: zhaijiaqi
 * @Date: 2025/6/24 10:58
 * @Description:
 **/
@RestController
@RequestMapping("/shop/dict")
public class DictController {

    @Autowired
    TbDictService tbDictService;

    /**
     * 根据类型ID获取字典列表
     * @param typeId
     * @return
     */
    @PostMapping("/getDictList/{typeId}")
    public R getDictList(@PathVariable("typeId") Integer typeId){
        return tbDictService.getDictList(typeId);
    }
}
